import request from '@/utils/request'

// 查询流程按钮列表
export function listBtn(query) {
  return request({
    url: '/flowable/btn/list',
    method: 'get',
    params: query
  })
}

// 查询流程按钮详细
export function getBtn(formId) {
  return request({
    url: '/flowable/btn/' + formId,
    method: 'get'
  })
}

// 新增流程按钮
export function addBtn(data) {
  return request({
    url: '/flowable/btn',
    method: 'post',
    data: data
  })
}

// 修改流程按钮
export function updateBtn(data) {
  return request({
    url: '/flowable/btn',
    method: 'put',
    data: data
  })
}
// 挂载按钮
export function addDeployBtn(data) {
  return request({
    url: '/flowable/btn/addDeployBtn',
    method: 'post',
    data: data
  })
}

// 删除流程按钮
export function delBtn(formId) {
  return request({
    url: '/flowable/btn/' + formId,
    method: 'delete'
  })
}

// 导出流程按钮
export function exportBtn(query) {
  return request({
    url: '/flowable/btn/export',
    method: 'get',
    params: query
  })
}
